<%--
  Created by IntelliJ IDEA.
  User: fight
  Date: 2019/9/20
  Time: 8:52
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="viewport" content="width=device-width"/>

    <link rel="stylesheet" href="css/index.css">
    <style>
        .main{
            display: flex;
            flex-direction: column;
        }
        .room-info{
            box-sizing: border-box;
            padding: 10px 20px 0;
            display: flex;
            justify-content: center;
            align-items: center;
            flex-direction: column;
        }
    </style>
</head>

<div class="main">
    <div class="room-info">
        <div class="me">
            我：<span>${user.username}</span>
        </div>
        <div class="enemy">
            对方：<span id="anotherUser">${user.enemy!=null?user.enemy.username:'等待加入...'}</span>
        </div>
    </div>
    <div class="game">
        <canvas id="chess" class="canvas" width="450" height="450"></canvas>
    </div>
</div>
<script type="text/javascript" src="js/chess.js">
</script>

<script>
    $('#btn-outRoom').removeClass('hide');
    $('#btn-createRoom').addClass('hide');
    $('#btn-restart').addClass('hide');

</script>